﻿using System;
using System.Collections.Generic;
using System.Linq;

namespace Protobuf_Gui.Domain
{
    public static class FieldTypeProvider
    {
        static FieldTypeProvider()
        {
            AddTypes();
        }

        private static void AddTypes()
        {
            var values = new List<string>()
            {
                "double",
                "float",
                "int32",
                "int64",
                "uint32",
                "uint64",
                "sint32",
                "sint64",
                "fixed32",
                "fixed64",
                "sfixed32",
                "sfixed64",
                "bool",
                "string",
                "bytes"
            };
            var types = from value in values select new PbFieldType(value);
            _list = new List<PbFieldType>(types);
        }

        private static List<PbFieldType> _list;

        public static List<PbFieldType> FieldTypes
        {
            get { return _list; }
        }
    }
}